<template>
  <div id="app">
    <!-- keep-alive这样返回时就不会返回顶部 而是返回刚才用户浏览的地方 -->
    <keep-alive>
      <router-view v-if="$route.meta.keepalive" />
    </keep-alive>
    <router-view v-if="!$route.meta.keepalive" />
  </div>
</template>

<style lang="css">
html {
  background-color: #f4f4f4;
}
</style>
